import Vue from 'vue'
import Router from 'vue-router'
import {PAGES} from '../api/config'

Vue.use(Router)

export default new Router({
  mode: 'hash',
  routes: [
    {
      path: '/',
      redirect: 'kidsworld'
      // name: 'HelloWorld',
      // component: HelloWorld
    },
    {
      path: '/kidsworld',
      name: 'kidsworld',
      component: PAGES['KidsWorld'],
      children: [
        {
          path: '',
          redirect: 'home',
        },
        {
          path: 'home',
          name: 'home',
          component: PAGES['Home']
        },
        {
          path: 'xsfc',
          name: 'xsfc',
          component: PAGES['Xsfc']
        },
        {
          path: 'sphx',
          name: 'sphx',
          component: PAGES['Sphx']
        },
        {
          path: 'xgbd',
          name: 'xgbd',
          component: PAGES['Xgbd']
        },
        {
          path: 'hzjg',
          name: 'hzjg',
          component: PAGES['Hzjg']
        },
        {
          path: 'infoDetail',
          name: 'infoDetail',
          component: PAGES['InfoDetail']
        },
        {
          path: 'pictureDetail',
          name: 'pictureDetail',
          component: PAGES['PictureDetail']
        },
        {
          path: 'videoDetail',
          name: 'videoDetail',
          component: PAGES['VideoDetail']
        },

      ]
    },

    // ,
    // {
    //   path: '/missworld',
    //   name: 'MissWorld',
    //   component: MissWorld
    // }
  ]
})
